﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ECRMS.Biz.Dom;
using ECRMS.Biz;
using ECRMS.Common;
using System.ServiceModel;

namespace ECRMS.Service
{
    //职位相关接口类
    [ServiceContract]
    public partial interface ICtEmployeeService
    {
         [OperationContract]
        CtServiceResult<List<CtEmployee>> CtGetEmployees(Guid corpId);
         [OperationContract]
        CtServiceResult<List<CtEmployee>> CtInsertEmployee(CtEmployee employee);
         [OperationContract]
        CtServiceResult<List<CtEmployee>> CtUpdateEmployee(CtEmployee employee);

    }

    public partial class ECRService : ICtUsrService
    {
        CtServiceResult<List<CtEmployee>> ICtEmployeeService.CtGetEmployees(Guid corpId)
        {
            var logic = new CtEmployeeLogic();
            return logic.GetEmployeesByCorpId(corpId);
        }

        CtServiceResult<List<CtEmployee>> ICtEmployeeService.CtInsertEmployee(CtEmployee employee)
        {
            var logic = new CtEmployeeLogic();
            return logic.Insert(employee);
        }

        CtServiceResult<List<CtEmployee>> ICtEmployeeService.CtUpdateEmployee(CtEmployee employee)
        {
            var logic = new CtEmployeeLogic();
            return logic.Update(employee);
        }

    }

    
}
